1. Field of the Invention
This invention relates generally to debugging computer programs, and more particularly, to systems and methods for simplifying and improving debugging of program code associated with developer-written computer program.
2. Description of the Related Art
As software applications (herein also referred to as applications) have become more and more complex, so has the process of debugging the applications. Currently, debugging an application involves traversing the entire execution path, so that any existing bugs (e.g., an error or defect) can be detected, identified, and eliminated. The execution path, however, includes computer program code written by the developer (herein also referred to as user) as well as computer system program executing the application and code generated by the computer system executing the application. Of course, the developer is merely interested in discovering and eliminating any existing bugs in the developer written application. Nonetheless, the user has to also debug system program code and tool-generated computer program code, which is unnecessary, a waste of developer's valuable time as well as computing power.
For instance, debugging a J2EE application using a Java debugger involves treating the J2EE application, code generated by tools (e.g., EJB compiler, JSP compiler etc.), and the application server configured to run the J2EE application, as a single Java program. It must be noted, however, that a significant portion of the single J2EE application program computer program code (hereinafter also referred to as the code) includes the application server code and tool-generated code, while only a small portion of the single Java program code is associated with the J2EE application code being debugged.
Defining a break point at a desired line of the single Java program code can facilitate debugging the single Java program. By way of example, the state of the single Java code at the break point can be displayed by the debugger using different debugger views (e.g., call stack view, a variable view, a thread view, etc.). However, the call stack includes the user-written code as well as the system computer program code and/or tool-generated computer program code. In the same manner, the variable view displays values of system generated variables, tool-generated variables, and developer-written variables while the thread view displays the threads in the developer-written code, system generated threads, and all threads generated by all the other applications running on the application server. As such, to monitor debugging of the J2EE application using any of the stack view, variable view, and thread view, the developer has to traverse each and every displayed stack, variable, and thread, so as to locate the bug, if any. Of course, examining each stack, variable, and thread is a tedious and time-consuming job, which unnecessarily wastes the developer's valuable time.
A debugging activity can also involve the stepping operation wherein each line of the single Java code is executed, one at a time, and the state of the application is displayed as each line of code is executed. The stepping operation can take control of system program code or tool-generated program code. As a result, the user has to go through several steps before the user reaches the next logical step in the user's application program code. During the stepping operation, the debugger views show state of the variables and methods as the debugger steps through each system code, tool-generated code, and user-written code, wasting the developer's valuable time.
In view of the foregoing, a need therefore exists in the art for an efficient computer program debugger capable of focusing the debugging operation on program code associated with a desired software application while bypassing non-associated program code.